//---------------------------------------------------------------------------

#ifndef DataModuleH
#define DataModuleH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <DB.hpp>
#include <IBDatabase.hpp>
#include <IBCustomDataSet.hpp>
#include <IBQuery.hpp>
#include <IBTable.hpp>
//---------------------------------------------------------------------------
class TDM : public TDataModule
{
__published:	// IDE-managed Components
        TIBTransaction *Trans;
        TIBDatabase *Base;
        TIBQuery *Ask;
        TIBTable *IBTable1;
        TIBQuery *UAsk;
private:	// User declarations
public:		// User declarations
        __fastcall TDM(TComponent* Owner);
        static void __fastcall LoadCombo(TComboBox * Combo, TIBQuery * Ask, String Text, String ID);
        static String __fastcall ComboVal(TComboBox * Combo);
        void __fastcall BaseUpdate();
};

String DeComa(String S)
{
 String SS = "";
 for(int i = 1; i<=S.Length(); i++)
 {
  if(S[i] == ',')
   SS = SS + ".";
  else
   SS = SS + S[i];
 }
 return SS;
}
String Coma(String S)
{
 String SS = "";
 for(int i = 1; i<=S.Length(); i++)
 {
  if(S[i] == '.')
   SS = SS + ",";
  else
   SS = SS + S[i];
 }
 return SS;
}
//---------------------------------------------------------------------------
extern PACKAGE TDM *DM;
//---------------------------------------------------------------------------
#endif
